﻿@model IEnumerable<VMFactory.Api.Data.Models.VMRequest>

@{
    ViewBag.Title = "Index";
}

<h2>List of VM jobs requested</h2>

This is the current list of requests made in the platform.

<p>
    @Html.ActionLink("Create New", "Create", "VMRequest")
</p>
<table>
    <tr>
        <th>
            @Html.DisplayNameFor(model => model.Id)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.RequestStatu.Name)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.CreatedOn)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.CreatedBy)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.VMTemplate.UniqueName)
        </th>
        <th />
    </tr>

@foreach (var item in Model) {
    
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Id)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.RequestStatu.Name)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.CreatedOn) UTC
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.CreatedBy)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.VMTemplate.UniqueName)
        </td>
        <td>
        </td>
    </tr>
}

</table>
